home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MACD 5
/
MACD 5.bin
/
workbench
/
tools
/
czesc_3
/
nerveex
/
installnerveex
< prev
next >
Wrap
Text File
|
1995-01-30
|
6KB
|
184 lines
; NerveEX Installer script by Torsten Ebeling (95/01/30)
(set @app-name "NerveEX")
(welcome " NerveEX installation script\n\n"
" Copyright 1994 by Torsten Ebeling\n\n"
"Novice installs everything except the developer files.\n"
"Advanced installs everything without confirmation.\n"
"Expert installs everything with confirmation of all actions.\n")
(set def_help "\n\nIf you need more help, please refer to \"NerveEX.guide\"\n\n")
(set @default-dest "SYS:c")
(set my_level @user-level)
(user 2)
(set nerveexdest
;get destination directory for "NerveEX"
(askdir (prompt "Select the directory where you want to put the NerveEX executable.")
(help "This should be a directory where you can easily access NerveEX "
"via Workbench or CLI/Shell." def_help @askdir-help)
(default @default-dest)
(disk)
)
)
(user my_level)
; Copy NerveEX files
(set @default-dest nerveexdest)
(set nerveextacked (tackon nerveexdest "NerveEX"))
; ask, if we want to overwrite the old NerveEX if it exists
(set overwrite 1)
(if (exists nerveextacked)
(
(set old_version (getversion nerveextacked))
(set old_ver (/ old_version 65536))
(set old_rev (- old_version (* old_ver 65536)))
(set new_version (getversion nerveextacked))
(set new_ver (/ new_version 65536))
(set new_rev (- new_version (* new_ver 65536)))
(set overwrite (askbool (prompt "\nYou have NerveEX "
old_ver "." old_rev " already installed"
".\nDo you wish to overwrite it with NerveEX "
new_ver "." new_rev " ?\n")
(help def_help @askbool-help)
(default 1)
(choices "Yes" "No"))
)
)
)
(if overwrite
(
; copy the new NerveEX file to the destination directory
(copyfiles (prompt ("\nCopying NerveEX to %s." nerveexdest))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source "")
(choices "prg/NerveEX" "prg/NerveEXPrefs")
(dest nerveexdest)
(confirm)
)
)
)
(set overwrite 0)
(if (exists "envarc:NerveEX.prefs")
(
(set overwrite (askbool (prompt "\nYou have an old preferences file already installed!"
".\nAll settings will be deleted if you overwrite the old one."
".\nDo you wish to overwrite it?")
(help def_help @askbool-help)
(default 0)
(choices "Yes" "No"))
)
)
)
(if overwrite
(
(copyfiles (prompt ("\nCopying NerveEX.prefs to envarc:"))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source "envarc/NerveEX.prefs")
(dest "envarc:")
(confirm)
)
(copyfiles (prompt ("\nCopying NerveEX.prefs to envarc:"))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source "envarc/NerveEX.prefs")
(dest "envarc:")
(confirm)
)
)
)
(set install_icons (askchoice (prompt "\nDo you want to install the icons ?\n")
(help def_help @askchoice-help)
(default 1)
(choices "No icons" "8 color icons" "4 color icons"))
)
(select install_icons
(set color_str "none")
(set color_str "8")
(set color_str "4")
)
(set NerveEXIcon (cat "icons/NerveEX_" color_str ".info"))
(set NerveEXPrefsIcon (cat "icons/NerveEXPrefs_" color_str ".info"))
(if install_icons
; then
(
(copyfiles (prompt ("\nCopying NerveEX %s color icons." color_str))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source NerveEXIcon)
(dest nerveexdest)
(newname "NerveEX.info")
(confirm)
)
(copyfiles (prompt ("\nCopying NerveEXPrefs %s color icons." color_str))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source NerveEXPrefsIcon)
(dest nerveexdest)
(newname "NerveEXPrefs.info")
(confirm)
)
)
)
; Copy guide file
(user 2)
(set docdest
;get destination directory for guide file
(askdir (prompt "Select the directory where you want to put the documents.")
(help def_help @askdir-help)
(default "HELP:")
(disk)
)
)
(user my_level)
; copy the new NerveEX.guide file to the destination directory
(copyfiles (prompt ("\nCopying NerveEX.guide to %s." docdest))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source "")
(choices "doc/NerveEX.guide")
(dest docdest)
(confirm)
)
(if install_icons
; then
(
(copyfiles (prompt ("\nCopying NerveEX.guide.info to %s." docdest))
(help def_help @copyfiles-help)
(optional "oknodelete")
(optional "askuser")
(source "doc/NerveEX.guide.info")
(dest docdest)
(newname "NerveEX.guide.info")
(confirm)
)
)
)